package com.jason.www.service;

import com.jason.www.pojo.GiftCard;

import java.util.List;

public interface IGiftCardService {

    GiftCard addGiftCard(GiftCard giftCard);

    GiftCard addGiftCard(GiftCard giftCard, long expire);

    List<GiftCard> addListGiftCard(List<GiftCard> listGiftCard);

    List<GiftCard> addListGiftCard(List<GiftCard> listGiftCard, long expire);


    void deleteGiftCard(Long id) ;

    void deleteListGiftCard(List<GiftCard> listGiftCard) ;


    int updateGiftCard(GiftCard giftCard);

    int updateGiftCard(GiftCard giftCard, boolean syncdb);

    int updateGiftCard(GiftCard giftCard, boolean syncdb, long expire);

    int updateGiftCardList(List<GiftCard> listGiftCard);

    int updateGiftCardList(List<GiftCard> listGiftCard, boolean syncdb);

    int updateGiftCardList(List<GiftCard> listGiftCard, boolean syncdb, long expire);


    Long getTotalGiftCard(GiftCard giftCard);

    void loadAllGiftCard();

    void loadAllGiftCard(long expire);

    GiftCard getGiftCardByKey(Long id);

    GiftCard getGiftCardByKey(Long id, long expire);

    List<GiftCard> getGiftCardByKeys(List<Long> ids);

    List<GiftCard> getGiftCardByPage(GiftCard giftCard, Boolean bFromCache, long expire);

    List<GiftCard> getGiftCardByPage(GiftCard giftCard, Boolean bFromCache);

}
